<%@ page language="java" contentType="text/html; charset=UTF-8"%>
<%@taglib prefix="s" uri="/struts-tags"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
	<head>
		<title><s:property value='%{getText("u_title")}' /></title>
		<link href="/SCMDB/style/main.css" rel="stylesheet" type="text/css" />
		<script type="text/javascript" src="/SCMDB/js/Super.js"></script>
		<s:include value="../commonPage/message.jsp" />
	</head>
	<body>
		<h2>
			<s:property value='%{getText("current_position")}' />${parentMenu}>>${currentMenu}
		</h2>
		<div class="main">
			<s:form action="userAction!findAll.action" method="post" theme="simple">
				<fieldset class="fieldSearch">
					<legend>
						<s:property value='%{getText("t_legend")}' />
					</legend>
					<table border="0" cellspacing="0" cellpadding="0">
				<tr>
				<td align="right" class="p_8"><s:property value='%{getText("u_name")}' />：</td><td><s:textfield name="userName"  cssClass="sInput" /></td>
				<td align="right" class="p_14"><s:property value='%{getText("u_role")}' />：</td><td><s:select list="#session.roleList" name="idRole" listKey="id" listValue="name" headerKey="0" headerValue="--请选择--"></s:select></td>
				<td align="right" class="p_14" colspan="2"><s:submit value="查询" cssClass="bSearch" /></td>
				</tr>
				</table>
				</fieldset>
				<p class="pEdit">
				 <%=request.getAttribute("button") %>
				</p>
				<table border="0" cellpadding="1" cellspacing="1" class="tableList">
					<thead>
						<tr>
							<th width="5%">
								<input type="checkbox" name="checkbox" value="checkbox"
									onclick="Super.checkAll(this.checked)" title="全选/取消" />
							</th>
							<th width="8%" class="number">
								<s:property value='%{getText("title_xuhao")}' />
							</th>
							<th width="40%">
								<s:property value='%{getText("u_name")}' />
							</th>
							<th width="45%">
								<s:property value='%{getText("u_role")}' />
							</th>
						</tr>
					</thead>
					<tbody>

						 <s:iterator id="pageBean" value="entity.list" status="u">
								<tr>
									<td>
										<input type="checkbox" name="checkbox" value="${pageBean.id}" />
									</td>
									<td class="number">
										${entity.index+u.index}
									</td>
									<td>
										${pageBean.userName}    
									</td>
				
									<s:if test="%{role!=null}">
										<td>
											${role.name}
										</td>
									</s:if>
									<s:else>
										<td></td>
									</s:else>
								</tr>
					</s:iterator>
					  <tr>
					<td colspan="4" class="turnPage">
						<jsp:include flush="true" page="../commonPage/page.jsp">
							<jsp:param name="entity" value="entity" />
						</jsp:include>
					</td>
				  </tr>
					</tbody>
				</table>
			</s:form>
		</div>
	</body>
</html>
<script>
function doDelete(){
	document.forms[0].action="tagManagerAction!delTag.action?id=1,3,3";
	document.forms[0].submit();
}
</script>
